<?php
/** 
 * Excepcion fatal de servicio.
 * @author gemu
 * 
 * 
 */
class FatalException extends Exception
{
	public $srcCode = null;
	
	function __construct($code, $msg=null, $srcCode=null){
		if($msg == null) {
			$reflector = new ReflectionClass('Constantes');
			$msgCode = $reflector->getConstant('MSG_'.$code);
			$msg = Language::getMessage($msgCode);
			
			$this->srcCode = $srcCode;
		}	
		parent::__construct($msg, $code);
   	}
}
?>